import { IAppOption } from 'whd-koa-base';
import * as path from 'path';

export const serverConfig: IAppOption = process.env.NODE_ENV === 'production' ?
    {
        port: 6789,
        home: path.resolve(process.cwd(), ''),
        logPath: 'logs',
        proxy: true,
        key: 'whd-conf',
        cors: {
            origin: '*'
        }
    } :
    {
        port: 6789,
        home: path.resolve(process.cwd(), ''),
        logPath: 'logs',
        proxy: false,
        key: 'whd-conf',
        cors: {
            origin: '*'
        }
    };
